import i18n from '@/locale/index';
import { useClipboard } from '@vueuse/core';
import { Message } from '@arco-design/web-vue';

export const copyAction = async (data: string) => {
  try {
    const { t } = i18n.global;
    const { copy } = useClipboard();
    await copy(data);
    Message.success(t('copy.success'));
  } catch (err) {
    // catch error
  }
};

export default null;
